docs(installation-jax): add bare-metal JAX/MaxText install guide and scripts#918
Open
amd-fuyuajin wants to merge 2 commits into
Open
docs(installation-jax): add bare-metal JAX/MaxText install guide and scripts#918amd-fuyuajin wants to merge 2 commits into
amd-fuyuajin wants to merge 2 commits into
Conversation
…scripts (v26.5) Add a no-Docker, no-sudo bare-metal installation path for the Primus JAX / MaxText training backend, mirroring the v26.5 JAX training Dockerfile. New tools/installation-jax/: - env.sh: sources the venv and exports ROCm (TheRock tarball), NVTE, and XLA runtime env; auto-detects the GPU arch (rocminfo -> KFD sysfs) so it works on gfx942/gfx950 without hand-editing; prefers Python 3.12 (prebuilt wheels are cp312). - setup.sh: re-runnable staged installer (ROCm tarball, MaxText, TensorFlow-CPU from source, ROCm JAX/PJRT/plugin, TransformerEngine, Primus, RCCL from source). The 'te' stage auto-falls-back to a from-source build on glibc < 2.38 hosts (e.g. Ubuntu 22.04); the tf_source build derives its Python wheel tag from the venv interpreter (cp312/cp313). - README.md: rationale and stage reference. New docs/01-getting-started/bare-metal-installation-jax.md: full manual guide with pinned versions, a version-requirements table (Python/glibc/toolchain/GPU prerequisites), and single- vs multi-node breakdown. Cross-linked from installation.md and bare-metal-installation.md (PyTorch guide relabeled). Validated end-to-end for single-node MaxText pretraining on gfx942 / Ubuntu 22.04 (glibc 2.35) / Python 3.12. Primus main already handles MaxText v26.5's 2-value initialize()/run() API (#912). Co-authored-by: Cursor <cursoragent@cursor.com>
amd-fuyuajin
requested review from
Xiaoming-AMD,
limou102 and
wenxie-amd
as code owners
July 24, 2026 15:05
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a no-Docker, no-sudo bare-metal installation path for the Primus JAX /
MaxText training backend, mirroring the v26.5 JAX training Dockerfile. This is
the JAX counterpart to the existing PyTorch
tools/installation/recipe, forusers who (for policy or operational reasons) cannot run containers.
What's added
tools/installation-jax/setup.sh— re-runnable staged installer: ROCmrelease tarball → MaxText → TensorFlow-CPU (from source) → ROCm JAX/PJRT/plugin
→ TransformerEngine → Primus → RCCL (from source).
tools/installation-jax/env.sh— sources the venv and exports all ROCm /NVTE_*/XLAbuild+runtime env.tools/installation-jax/README.md— rationale and stage reference.docs/01-getting-started/bare-metal-installation-jax.md— full manualguide: pinned versions, a version-requirements table (Python/glibc/toolchain/GPU
prerequisites), and a single- vs multi-node breakdown.
installation.mdandbare-metal-installation.md(PyTorchguide relabeled).
Notable design points
TensorFlow
upstream-v2.21.0, RCCL9e5e408, MaxTextrelease/v26.5.rocminfo→ KFD sysfs); thetestage auto-falls-back to a from-sourcebuild on glibc < 2.38 (e.g. Ubuntu 22.04); the TF source build derives its
wheel tag from the venv Python (cp312/cp313).
PRIMUS_JAX_BASEis required (no default) — the scripts fail fast with aclear message if it is unset.
/opt/rocm.Not included (documented as manual/root steps)
apt) packages (guide Section 2) and the multi-node networking stack(UCX/OpenMPI/AINIC, guide Section 4).
Test plan
Ubuntu 22.04 (glibc 2.35) / Python 3.12.
bash setup.sh --listand staged re-runs;bash -nclean.pre-commit(shellcheck, black, isort, trailing-whitespace, …) passes onall changed files.
main's MaxText v26.5 2-valueinitialize()/run()support(fix(maxtext): handle v26.5 2-value initialize()/run() API #912), already merged.